package homework.day06;

/**
 * @Classname: HomeWork01
 * @Author: bromide
 * @CreateTime: 2022/4/3--下午12:00
 * @Version: V1.0
 * @Description: * 改正下面程序的错误,使得程序可以正常运行
 * *
 * * 使用第二种创建线程方式创建一条线程，并输出100次:你好
 */
public class HomeWork01 {
    public static void main(String[] args) {
        MyRunnable run = new MyRunnable();
        Thread t = new Thread(run);
        t.start();
    }
}

class MyRunnable implements Runnable {
    public void run() {
        for (int i = 0; i < 100; i++) {
            System.out.println("你好!");
        }
    }
}
